{% load static %}
{% load blog_extras %}
<!DOCTYPE html>
<html>
<head>
    <title>XKOJ - Blog</title>

    <!-- meta -->
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">

    <!-- css -->
	<link rel="stylesheet" href="{% static "semantic/semantic/dist/semantic.min.css" %}"/>
	<link rel="stylesheet" href="{% static "semantic/semantic/dist/semantic.css" %}"/>
	<link rel="stylesheet" href="{% static "css/Ace.css" %}"/>
	<link rel="stylesheet" href="{% static "css/blogs.css" %}"/>
	<script src="{% static "js/jquery-1.11.0.min.js" %}"></script>
	<script src="{% static "semantic/semantic/dist/semantic.min.js" %}"></script>
	<script src = "{% static "semantic/semantic/dist/semantic.js" %}"> </script>
    
<!--    <link rel="stylesheet" href="{% static 'blogs/css/ionicons.min.css' %}">-->
    <link rel="stylesheet" href="https://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css">
    <link rel="stylesheet" href="{% static 'blogs/css/bootstrap.min.css' %}">
    <link rel="stylesheet" href="{% static 'blogs/css/pace.css' %}">
    <link rel="stylesheet" href="{% static 'blogs/css/custom.css' %}">
    <link href="https://cdn.bootcss.com/highlight.js/9.15.8/styles/github.min.css" rel="stylesheet">
    <style>
	    .codehilite {
	      padding: 0;
	    }
	    /* for block of numbers */
	    .hljs-ln-numbers {
	      -webkit-touch-callout: none;
	      -webkit-user-select: none;
	      -khtml-user-select: none;
	      -moz-user-select: none;
	      -ms-user-select: none;
	      user-select: none;
	      text-align: center;
	      color: #ccc;
	      border-right: 1px solid #CCC;
	      vertical-align: top;
	      padding-right: 5px;
	    }
	    .hljs-ln-n {
	      width: 30px;
	    }
	    .hljs-ln .hljs-ln-code {
	      padding-left: 10px;
	      white-space: pre;
	    }
    </style>
	
    <!-- js -->
    <script src="{% static 'blogs/js/jquery-2.1.3.min.js' %}"></script>
    <script src="{% static 'blogs/js/bootstrap.min.js' %}"></script>
    <script src="{% static 'blogs/js/pace.min.js' %}"></script>
    <script src="{% static 'blogs/js/modernizr.custom.js' %}"></script>
</head>

<body>
<div>
	<div class="ui inverted menu pointing">
		<div class="item header" href="/" style="font-size: 14px">XKOJ</div>
		<a class="item" href="/" style="font-size: 14px">主页</a>
		<a class="item" href="/problems" style="font-size: 14px">题目集</a>
		<a class="item" href="/games" style="font-size: 14px">比赛</a>
		<a class="item" href="/blogs" style="font-size: 14px">博客</a>
		<a class="item" href="/about" style="font-size: 14px">关于</a>
		{% if user.is_superuser %}
				<a class="item" href="/add_problem" style="font-size: 14px">添加题目</a>
		{% endif %}
          {% block submit %}
          {% endblock %}
		<div class="right menu">
			<div class="item">
                <div class="ui action left icon input">
                    <i class="search icon"></i>
                    <input type="text">
                    <button class="ui button">搜索</button>
                </div>
            </div>
            <a class="item" style="font-size: 14px">联系我们</a>
			{% if user.is_authenticated %}
				<a href="/logout" class="ui item botton" style="font-size: 14px">登出</a>
			{% else %}
				<a href="/login" class="ui item botton" style="font-size: 14px">注册/登录</a>
			{% endif %}
		</div>
	</div>
</div>
<div class="container">
    {% if messages %}
        {% for message in messages %}
        <div class="alert alert-{{ message.tag }} alert-dismissible" role="alert">
        <button type="botton" class="close" data-dismiss="alert" aria-label="Close">
        	<span aria-hidden="true">&times;</span>
        </botton>
        {{ message }}
        </div>
        {% endfor %}
    {% endif %}
</div>

<div class="content-body">
    <div class="container">
        <div class="row">
        	  <main class="col-md-8">
            	 {% block main %}
    			 {% endblock main %}
            </main>
            <aside class="col-md-4">
			 {% block toc %}
			 {% endblock toc %}

			 {% show_recent_posts %}
			 {% show_archives %}
			 {% show_categories %}
			 {% show_tags %}

			 <div class="rss">
			 	<a href=""><span class="ion-social-rss-outline"></span> RSS 订阅</a>
			 </div>
            </aside>
        </div>
    </div>
</div>
<footer id="site-footer">
    <div class="container">
        <div class="row">
            <div class="col-md-12">
                <p class="copyright">&copy 2022 - iuk11 大创项目 “基于Django和Vue的在线测评与博客系统”
                </p>
            </div>
        </div>
    </div>
</footer>

<!-- Mobile Menu -->
<div class="overlay overlay-hugeinc">
    <button type="button" class="overlay-close"><span class="ion-ios-close-empty"></span></button>
    <nav>
        <ul>
            <li><a href="/">首页</a></li>
            <li><a href="/blogs">博客</a></li>
            <li><a href="/about">关于</a></li>
            <li><a href="/">联系</a></li>
        </ul>
    </nav>
</div>

<script src="{% static 'blogs/js/script.js' %}"></script>
<script src="https://cdn.bootcss.com/highlight.js/9.15.8/highlight.min.js"></script>
<script src="https://cdn.bootcss.com/highlightjs-line-numbers.js/2.7.0/highlightjs-line-numbers.min.js"></script>
<script>
   hljs.initHighlightingOnLoad();
   hljs.initLineNumbersOnLoad();
</script>
</body>
</html>
